using System;
using System.Collections.Generic;
using System.Data.Linq.Mapping;
using InfoTech.Core.Data.Attributes;
using InfoTech.Core.Data.Dataable;
using InfoTech.Core.Data.Persistence;
using InfoTech.Utilities.Generic;

namespace InfoTech.LanTranh.MucVu.Bussiness
{
	[Serializable]
	[ExtraTable(Name = "CONFIGURATION", Schema="dbo")]
	[Table(Name = "[dbo].[CONFIGURATION]")]
	public partial class CONFIGURATION : ObjPersistence, IDeleteable, IUpdateable, IInsertable, ISelectable, IDeleteablebyId, IUpdateablebyId, ISelectablebyId
	{

		#region Fields

		private System.Guid _configurationid;

		private System.String _key;

		private System.String _value;

		private System.Int32? _id;

		#endregion

		#region Properties

		[ExtraColumn(DbType = "uniqueidentifier", Length = 0, TypeName = "System.Guid", Type = typeof(System.Guid), CanBeNull = false)]
		[Column(Name = "ConfigurationID", DbType = "uniqueidentifier", IsPrimaryKey = true, CanBeNull = false)]
		public System.Guid CONFIGURATIONID
		{
			get
			{
				return _configurationid;
			}
			set
			{
				OnChanged(this, "CONFIGURATIONID");
				_configurationid = value;
			}
		}

		[ExtraColumn(DbType = "nvarchar", Length = 1000, TypeName = "System.String", Type = typeof(System.String), CanBeNull = true)]
		[Column(Name = "KEY", DbType = "nvarchar(1000)", IsPrimaryKey = false, CanBeNull = true)]
		public System.String KEY
		{
			get
			{
				return _key;
			}
			set
			{
				OnChanged(this, "KEY");
				_key = value;
			}
		}

		[ExtraColumn(DbType = "nvarchar", Length = 1000, TypeName = "System.String", Type = typeof(System.String), CanBeNull = true)]
		[Column(Name = "VALUE", DbType = "nvarchar(1000)", IsPrimaryKey = false, CanBeNull = true)]
		public System.String VALUE
		{
			get
			{
				return _value;
			}
			set
			{
				OnChanged(this, "VALUE");
				_value = value;
			}
		}

		[ExtraColumn(DbType = "int", Length = 0, TypeName = "System.Int32", Type = typeof(System.Int32), CanBeNull = true)]
		[Column(Name = "ID", DbType = "int", IsPrimaryKey = false, CanBeNull = true)]
		public System.Int32? ID
		{
			get
			{
				return _id;
			}
			set
			{
				OnChanged(this, "ID");
				_id = value;
			}
		}

		#endregion

		#region Reflector

		public System.Type Reflector()
		{
			return typeof(CONFIGURATION);
		}
		public object Current
		{
			get { return this; }
		}

		#endregion

	}
}
